<?php include("header.php"); ?>

	<div id="content">  
		Silahkan isi form untuk melakukan order :
		<?php
//include file
include("include/session.php");
require_once('db_conn/conn_db.php');
require_once('header.php');
require_once('calendar/calendar/classes/tc_calendar.php');
?>
<script language="javascript" src="calendar/calendar/calendar.js"></script>
<SCRIPT LANGUAGE="JavaScript">
function fjs_formval()
	{
	error = 0;
	if (window.document.form.tema.value == "")
	{
		alert("ATTENTION \n\nField Tema Buku must be filled.");
		window.document.form.tema.focus();
		error = 1;
	}
	
	else
	if (window.document.form.judul.value == "")
	{
		alert("ATTENTION \n\nField Judul Buku must be filled.");
		window.document.form.judul.focus();
		error = 1;
	}
	
	if (error == 0)
		window.document.form.submit();
	else
	return false;
}</SCRIPT>
<FORM ACTION="admin/save_order.php?action=save" method="post" name="form" id="form">
<table align="left" cellpadding="1" cellspacing="1" border="1">
    <input type=hidden name=status value="1" size=20>
	<tr>
		<td class="pageName" colspan="2">Form Order</td>
	</tr>
	<input type=hidden name=klien_id value=<?php echo $_SESSION[user_id]?>>
	<tr> 
      <td>Tema Buku</td>
	  <td><input type=text name=tema size=40></td>
    </tr>
	<tr> 
      <td>Judul Buku</td>
	  <td><input type=text name=judul size=40></td>
    </tr>
	<tr> 
      <td>Jumlah Halaman</td>
	  <td><input type=text name=jumlah size=15></td>
    </tr>	
	<tr> 
      <td>Cover</td>
	  <td><input type=text name=cover size=40></td>
    </tr>
	<tr> 
    <td>Target Finished</td>
	  <td>
		<?php
		  $myCalendar = new tc_calendar("target", true, false);
		  $myCalendar->setIcon("calendar/calendar/images/iconCalendar.gif");
		  $myCalendar->setDate(date('d'), date('m'), date('Y'));
		  $myCalendar->setPath("calendar/calendar/");
		  $myCalendar->setYearInterval(2010, 2015);
		  $myCalendar->dateAllow("2013-01-01", '2015-03-01');
		  $myCalendar->setDateFormat('j F Y');
		  //$myCalendar->setHeight(350);	  
		  //$myCalendar->autoSubmit(true, "form1");
		  $myCalendar->setAlignment('left', 'bottom');
		  $myCalendar->setSpecificDate(array("2013-01-01", "2013-01-01", "2111-12-25"), 0, 'year');
		  $myCalendar->writeScript();
		  ?>
	  </td>
    </tr>
	 <td><input type=submit value=Simpan onClick="javascript:return fjs_formval()"> <input type=reset value=Reset></td>
    </tr>
</table>
</FORM>
	</div>

<?php include("footer.php"); ?>